<?php

declare(strict_types=1);

namespace App\Library\Task\library\queue\drivers;

/**
 * 队列驱动服务端接口,所有的服务端驱动必须继承
 * Interface DriverServerImp
 * @package app\common\libraries\queue\drivers
 */
interface DriverServerImp{

    /**
     * 取出队列
     * @param unknown $key
     * @param $time 监听时间
     */
    public function pop($key, $time);

    /**
     *获取队列所有的key
     * @param $driver 驱动
     * @return mixed
     */
    public function scan($driver);

    /**
     * 清理key
     * @param $driver 驱动
     * @return mixed
     */
    public function clear($driver);

}